package com.jiexinyun.sftp.jsch;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Data
@Component
@ConfigurationProperties(prefix = "sftp")
public class SftpProperties {

    private String host;
    private int port;
    private String username;
    private String password;
    private String basePath;

    // 连接池配置
    private Pool pool = new Pool();

    @Data
    public static class Pool {
        private int maxTotal = 8;
        private int minIdle = 2;
        private int maxIdle = 4;
        private int sessionTimout = 4;
        private int maxWait = 5;//单位秒
    }

}
